package cn.tfyhyc.springcloud.service.impl;

import cn.tfyhyc.springcloud.dao.StorageDao;
import cn.tfyhyc.springcloud.service.StorageService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * @author 头发又黑又长
 * @Date 2022/10/30 15:54
 * @email zwb15083976291@163.com
 */
@Service
public class StorageServiceImpl implements StorageService {

    @Resource
    private StorageDao storageDao;

    @Override
    public void decrease(Long productId, Integer count) {
        System.out.println("-------------> storage-service中扣减库存 开始");
        storageDao.decrease(productId, count);
        System.out.println("-------------> storage-service中扣减库存 结束");
    }
}
